package com.turing.data.scripts.contract.transfer

import com.turing.data.vo.out.review.DependParamsVO
import com.turing.data.vo.out.review.TaskElementVO


/**
 * 场景：资产管理合同-v3.0
 * 版本：Version 3.0
 * 要素名称：预警线数额
 */

class WarningLineNumber_30194_10_transfer {

    static List< TaskElementVO.DrawResultVO > doConvert(List< TaskElementVO.DrawResultVO > resultVOs, DependParamsVO dependParams){

        def regex = /.*【(\d+.\d+)】/

        if (resultVOs!=null && resultVOs.size()>0){
            for (int i = 0; i < resultVOs.size(); i++) {
                String modelValue = resultVOs.get(i).getText()
                if(modelValue =~ regex){
                    def value = ( modelValue =~ regex )
                    resultVOs.get(i).businessValue = value[0][1]
                }
                resultVOs.get(i).type = 1
            }
        }

        return  resultVOs
    }
}
